calculating glare